#pragma once

#include <Windows.h>

#include "../Time/WhyTime.h"
#include "../States/WhyStateSystem.h"
#include "../Graphics/WhyGraphics.h"
#include "../Events/WhyEventSystem.h"
#include "../Input/WhyInput.h"

class WhyEngine
{
	static WhyTime*			time;
	static WhyStateSystem*	states;
	static WhyGraphics*		graphics;
	static WhyEventSystem*	events;
	static WhyInput*		input;

public:

	static WhyTime& Time()				{ return *time; }
	static WhyStateSystem& States()		{ return *states; }
	static WhyGraphics& Graphics()		{ return *graphics; }
	static WhyEventSystem& Events()		{ return *events; }
	static WhyInput& Input()			{ return *input; }

private:

	static void Update();

	static void Render();

public:

	static void PreInitialize();

	static void Initialize(HWND hwnd, HINSTANCE hInstance, int screenWidth, int screenHeight, bool isWindowed = true, bool vsync = false);

	static bool Main();

	static void ShutDown();
};